package com.cc.controller;

import com.cc.comm.responce.PageResult;
import com.cc.comm.responce.R;
import com.cc.model.dto.SupplierQuery;
import com.cc.model.entity.Suppliers;
import com.cc.service.SuppliersService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 供应商表 前端控制器
 * </p>
 *
 * @author 晓东√
 * @since 2025-09-19 11:18
 */
@RestController
@RequestMapping("/suppliers")
public class SuppliersController {
    @Autowired
    private SuppliersService suppliersService;
    @PostMapping("/list")
    public R<PageResult<Suppliers>> getSupplierPage(SupplierQuery supplierQuery) {
        PageResult<Suppliers> suppliersPage = suppliersService.getSupplierPage(supplierQuery);
        return R.success(suppliersPage);
    }

}
